package com.wang.loanassembly.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 
 * </p>
 *
 * @author lichacha
 * @since 2022-01-04
 */
public class RepaymentSchedule implements Serializable {

    private static final long serialVersionUID = 1L;

      @TableId(value = "rs_id", type = IdType.AUTO)
    private Integer rsId;

    /**
     * 贷款id
     */
    private Integer rsLoanId;

    /**
     * 还款时间 ，每月固定
     */
    private LocalDateTime rsRepayTime;

    /**
     * 还款金额
     */
    private Double rsRepayAmount;

    /**
     * 偿还本金
     */
    private Double rsPrincipal;

    /**
     * 偿还利息
     */
    private Double rsInterest;

    /**
     * 剩余金额
     */
    private Double rsResidualAmount;

    /**
     * 剩余利息
     */
    private Double rsResidualInteres;

    /**
     * 本期是否按时还款 0 正常还款  1 没有
     */
    private Integer reRepayState;

    /**
     * 记录新增时间
     */
    private LocalDateTime rawAddTime;

    /**
     * 记录更新时间
     */
    private LocalDateTime rawUpdateTime;


    public Integer getRsId() {
        return rsId;
    }

    public void setRsId(Integer rsId) {
        this.rsId = rsId;
    }

    public Integer getRsLoanId() {
        return rsLoanId;
    }

    public void setRsLoanId(Integer rsLoanId) {
        this.rsLoanId = rsLoanId;
    }

    public LocalDateTime getRsRepayTime() {
        return rsRepayTime;
    }

    public void setRsRepayTime(LocalDateTime rsRepayTime) {
        this.rsRepayTime = rsRepayTime;
    }

    public Double getRsRepayAmount() {
        return rsRepayAmount;
    }

    public void setRsRepayAmount(Double rsRepayAmount) {
        this.rsRepayAmount = rsRepayAmount;
    }

    public Double getRsPrincipal() {
        return rsPrincipal;
    }

    public void setRsPrincipal(Double rsPrincipal) {
        this.rsPrincipal = rsPrincipal;
    }

    public Double getRsInterest() {
        return rsInterest;
    }

    public void setRsInterest(Double rsInterest) {
        this.rsInterest = rsInterest;
    }

    public Double getRsResidualAmount() {
        return rsResidualAmount;
    }

    public void setRsResidualAmount(Double rsResidualAmount) {
        this.rsResidualAmount = rsResidualAmount;
    }

    public Double getRsResidualInteres() {
        return rsResidualInteres;
    }

    public void setRsResidualInteres(Double rsResidualInteres) {
        this.rsResidualInteres = rsResidualInteres;
    }

    public Integer getReRepayState() {
        return reRepayState;
    }

    public void setReRepayState(Integer reRepayState) {
        this.reRepayState = reRepayState;
    }

    public LocalDateTime getRawAddTime() {
        return rawAddTime;
    }

    public void setRawAddTime(LocalDateTime rawAddTime) {
        this.rawAddTime = rawAddTime;
    }

    public LocalDateTime getRawUpdateTime() {
        return rawUpdateTime;
    }

    public void setRawUpdateTime(LocalDateTime rawUpdateTime) {
        this.rawUpdateTime = rawUpdateTime;
    }

    @Override
    public String toString() {
        return "RepaymentSchedule{" +
        "rsId=" + rsId +
        ", rsLoanId=" + rsLoanId +
        ", rsRepayTime=" + rsRepayTime +
        ", rsRepayAmount=" + rsRepayAmount +
        ", rsPrincipal=" + rsPrincipal +
        ", rsInterest=" + rsInterest +
        ", rsResidualAmount=" + rsResidualAmount +
        ", rsResidualInteres=" + rsResidualInteres +
        ", reRepayState=" + reRepayState +
        ", rawAddTime=" + rawAddTime +
        ", rawUpdateTime=" + rawUpdateTime +
        "}";
    }
}
